﻿<!DOCTYPE html>
<!--
Beyond Admin - Responsive Admin Dashboard Template build with Twitter Bootstrap 3
Version: 1.0.0
Purchase: http://wrapbootstrap.com
-->

<html xmlns="http://www.w3.org/1999/xhtml">
<!--Head-->
<head>
    <meta charset="utf-8" />
    <title>登录页</title>

    <meta name="description" content="login page" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <link rel="shortcut icon" href="assets/img/favicon.png" type="image/x-icon">
    <!--Basic Styles-->
    <link href="../unis/bootstrap.min.css" rel="stylesheet" />
    <link id="beyond-link" href="../unis/beyond.min.css" rel="stylesheet" />
    <link href="../unis/animate.min.css" rel="stylesheet" />
    <style>
        body{
            font-family: '微软雅黑';
        }
    </style>
</head>
<!--Head Ends-->
<!--Body-->
<body>
    <div class="login-container animated fadeInDown">
        <div class="loginbox bg-white">
            <div class="loginbox-title">欢乐卡卡-襄阳卡五星</div>
            <div class="loginbox-social">
                <div class="social-title ">游戏登录</div>
                <div class="social-buttons">
                    <a href="" class="button-facebook">
                        <i class="social-icon fa fa-facebook"></i>
                    </a>
                    <a href="" class="button-twitter">
                        <i class="social-icon fa fa-twitter"></i>
                    </a>
                    <a href="" class="button-google">
                        <i class="social-icon fa fa-google-plus"></i>
                    </a>
                </div>
            </div>
            <div class="loginbox-textbox">
                <input type="text" name="username" id="username" class="form-control" placeholder="账号" />
            </div>
            <div class="loginbox-textbox">
                <input type="password"  name="pwd" id="pwd"   class="form-control" placeholder="密码" />
            </div>
           
            <div class="loginbox-submit">
                <input type="button"class="btn btn-primary btn-block" id="lod" value="登录"  >
            </div>
           
        </div>
        
    </div>
</body>
<script src="../unis/jquery-1.8.3.min.js"></script>
<script src="../interface/interface.js"></script>
<script>
    $('#lod').on('click',function(){
        var username = $('#username').val();
        var pwd = $('#pwd').val();
        var opt = {
            type : 'POST',
            url : 'http://mj.lcc.so/login',
            data : 'username='+username+'&pwd='+pwd
        };
        window.getData(opt,function(data){
            if(data.status==1){
                var token = data.token;
                var mid = data.mid;
                var url = window.location.href;
                url = url.replace('login','NewRoom');
                window.location.href = url+'?mid='+mid+'&token='+token ;
            }else{
                alert('账号密码错误 ~ 请重新输入~')
            }
        })
    })
</script>
</html>
